Now that we know where the clip has been dropped, we can then take that information and process it using if…then conditional statements to see if it’s been dropped on anywhere specific, and act accordingly. For instance, this is the line of code in Psycho Studio which detects that the clip has been dropped on the preview window (it’s attached to the buttons in the thumbnails movie that we looked at earlier):
if (getProperty( ΓÇ£../../iconΓÇ¥, _droptarget) eq ΓÇ£/preview/screenΓÇ¥) {
/preview/screen is the _droptarget returned when the clip is dropped on the preview window. This is because the preview window is made up of two movie clips, one with the instance name preview and another inside that with the instance name screen. So we know if this value is returned from _droptarget, we need to load the relevant clip into the preview window.
And thatΓÇÖs it. I hope this technique will be useful for you when youΓÇÖre designing your own material, and IΓÇÖve included my fla files on the accompanying CD for you to download and experiment with, if youΓÇÖll find that helpful.